#include <stdio.h>

int main(int argc, char *argv[])
{
	int i = 0, j = 0;
	while(scanf("%d", &i) && i)
	{
		if(i < 0 || i != 0)
			++j;
	}
	printf("%d\n", j);
	return 0;
}
